/*
 * cStateBase.h
 *
 *  Created on: 11.2.2009
 *      Author: jari.ravantti
 *      RESOURCE for statemanager:
 *		http://gamedevgeek.com/tutorials/managing-game-states-in-c/
 *
 */

#ifndef CSTATEBASE_H_
#define CSTATEBASE_H_

#include "CStateManager.h"


class CStateBase {

public:

	virtual void Init() = 0;
	virtual void Cleanup() = 0;

	virtual void Pause() = 0;
	virtual void Resume() = 0;

	virtual void HandleEvents(CStateManager* main) = 0;
	virtual void Update(CStateManager* main) = 0;
	virtual void Draw(CStateManager* main) = 0;

	void ChangeState(CStateManager *main, CStateBase *state) {
		main->ChangeState(state);
	}

protected:
	CStateBase() {
	}

};

#endif /* CSTATEBASE_H_ */
